﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Slja.Utility;

namespace Slja.Model
{
  
        /// <summary>
        /// OrderModel:订单实体类
        /// </summary>
        [Serializable]
        public partial class OrderModel
        {
            public OrderModel()
            { }
            #region Model
            private int _id;
            private string _prjid;
            private string _prjname;
            private int _manageruser;
            private string _managerusername;
            private DateTime? _planstartdate;
            private DateTime? _planenddate;
            private int _shopid;
            private int _clientid;
            private string _clientname;
            private string _region;
            private int? _city;
            private string _producttype;
            private int? _saletype;
            private int? _agentclientid;
            private int? _planmaker;
            private int? _saleman;
            private string _agentsaleman;
            private DateTime? _createtime;
            private int? _creator;
            /*当前操作人*/
            private int _curopuserid;
            private string _curopusername;
            /*状态 */
            int _salestatelog;
            int _backstate;
            SaleState _enum_presalestate;
            SaleState _enum_backstate;
            string _statusdescr;
            /* 备注信息 */
            string _clientmemo;
            string _managememo;
            string _designmemo;
            string _pricememo;
            /// <summary>
            /// 自增ID
            /// </summary>
            public int ID
            {
                set { _id = value; }
                get { return _id; }
            }
            /// <summary>
            /// 项目ID
            /// </summary>
            public string PrjID
            {
                set { _prjid = value; }
                get { return _prjid; }
            }
            /// <summary>
            /// 项目名称
            /// </summary>
            public string PrjName
            {
                set { _prjname = value; }
                get { return _prjname; }
            }
            /// <summary>
            /// 项目管理人ID(项目经理ID)
            /// </summary>
            public int ManagerUser
            {
                set { _manageruser = value; }
                get { return _manageruser; }
            }
            /// <summary>
            /// 项目管理人姓名(项目经理)
            /// </summary>
            public string ManagerUserName
            {
                set { _managerusername = value; }
                get { return _managerusername; }
            }
            /// <summary>
            /// 计划开始时间
            /// </summary>
            public DateTime? PlanStartDate
            {
                set { _planstartdate = value; }
                get { return _planstartdate; }
            }
            /// <summary>
            /// 计划结束时间
            /// </summary>
            public DateTime? PlanEndDate
            {
                set { _planenddate = value; }
                get { return _planenddate; }
            }
            /// <summary>
            /// 商店ID
            /// </summary>
            public int ShopID
            {
                set { _shopid = value; }
                get { return _shopid; }
            }
            /// <summary>
            /// 客户ID
            /// </summary>
            public int ClientID
            {
                set { _clientid = value; }
                get { return _clientid; }
            }
            /// <summary>
            /// 客户名称
            /// </summary>
            public string ClientName
            {
                set { _clientname = value; }
                get { return _clientname; }
            }
            /// <summary>
            /// 区域
            /// </summary>
            public string Region
            {
                set { _region = value; }
                get { return _region; }
            }
            /// <summary>
            /// 城市
            /// </summary>
            public int? City
            {
                set { _city = value; }
                get { return _city; }
            }
            /// <summary>
            /// 产品类型（美键、数码）
            /// </summary>
            public string ProductType
            {
                set { _producttype = value; }
                get { return _producttype; }
            }
            /// <summary>
            /// 销售方式(直营\代理)
            /// </summary>
            public int? SaleType
            {
                set { _saletype = value; }
                get { return _saletype; }
            }
            /// <summary>
            /// 代理商ID（客户的一种）
            /// </summary>
            public int? AgentClientID
            {
                set { _agentclientid = value; }
                get { return _agentclientid; }
            }
            /// <summary>
            /// 企划人ID
            /// </summary>
            public int? PlanMaker
            {
                set { _planmaker = value; }
                get { return _planmaker; }
            }
            /// <summary>
            /// 营业人ID
            /// </summary>
            public int? SaleMan
            {
                set { _saleman = value; }
                get { return _saleman; }
            }
            /// <summary>
            /// 代理商营业
            /// </summary>
            public string AgentSaleMan
            {
                set { _agentsaleman = value; }
                get { return _agentsaleman; }
            }
            /// <summary>
            /// 创建时间
            /// </summary>
            public DateTime? CreateTime
            {
                set { _createtime = value; }
                get { return _createtime; }
            }
            /// <summary>
            /// 创建用户ID
            /// </summary>
            public int? Creator
            {
                set { _creator = value; }
                get { return _creator; }
            }
            /// <summary>
            /// 状态位n（执行进度）
            /// </summary>
            public int SaleStateLog { set { _salestatelog = value; } get { return _salestatelog; } }
            /// <summary>
            /// 状态位n（回退进度）
            /// </summary>
            public int BackState { set { _backstate = value; } get { return _backstate; } }
            /// <summary>
            /// 状态描述
            /// </summary>
            public string StatusDescr { set { _statusdescr = value; } get { return _statusdescr; } }
            /// <summary>
            /// 状态(取SaleStateLog属性最高位的"1"的代表的枚举值)
            /// </summary>            
            public SaleState Enum_SaleState { set { _enum_presalestate = value; } get { return _enum_presalestate; } }
            /// <summary>
            /// 回退状态(枚举)
            /// </summary>            
            public SaleState Enum_BackState { set { _enum_backstate = value; } get { return _enum_backstate; } }
            /// <summary>
            /// 当前操作人ID
            /// </summary>
            public int CurOpUserID { set { _curopuserid = value; } get { return _curopuserid; } }
            /// <summary>
            /// 当前操作人Name
            /// </summary>
            public string CurOpUserName { set { _curopusername = value; } get { return _curopusername; } }
            /// <summary>
            /// 客户备注信息
            /// </summary>
            public string ClientMemo { set { _clientmemo = value; } get { return _clientmemo; } }
            /// <summary>
            /// 项目管理备注信息
            /// </summary>
            public string ManageMemo { set { _managememo = value; } get { return _managememo; } }
            /// <summary>
            /// 设计备注信息
            /// </summary>
            public string DesignMemo { set { _designmemo = value; } get { return _designmemo; } }
            /// <summary>
            /// 报价备注信息
            /// </summary>
            public string PriceMemo { set { _pricememo = value; } get { return _pricememo; } }
            #endregion Model

        }
        /// <summary>
        /// OrderExtModel:订单实体扩展类
        /// </summary>
        [Serializable]
        public partial class OrderExtModel:OrderModel
        {
            public OrderExtModel()
            { }
            /* 商店信息 */
            string _cityname;
            string _shopname;
            string _shoplinkman;
            string _shoplinkmantel;
            string _shoppromotor;
            string _tlcode;
            string _shopinnercode;
            string _address;
            string _ShopLev;
            string _SaleVolume;
            string _ShopSquare;
            /* 企划\营业 */
            string _planmakername;
            string _planmakertel;
            string _salemanname;    
            string _salemantel;
            /* 代理商 */
            string _agentclientname;
            string _agentclientlinkman;
            string _agentclientlinktel;
            /*该订单的各角色工作人员 */
            List<OrderWorkTeamModel> _team;
            /*该订单的文件 */
            List<OrderFilesModel> _filelist;
            
            /// <summary>
            /// 城市名
            /// </summary>
            public string CityName { set { _cityname = value;} get { return _cityname;} }
            /// <summary>
            /// 商店名
            /// </summary>
            public string ShopName { set { _shopname= value;} get { return _shopname;} }
            /// <summary>
            /// 商店联系人
            /// </summary>
             public string ShopLinkMan { set { _shoplinkman= value;} get { return _shoplinkman;} }
            /// <summary>
            /// 商店联系人电话
            /// </summary>
            public string ShopLinkManTel { set { _shoplinkmantel= value;} get { return _shoplinkmantel ;} }
            /// <summary>
            /// 商店促销员
            /// </summary>
            public string ShopPromotor { set { _shoppromotor= value;} get { return _shoppromotor ;} }
            /// <summary>
            /// 腾龙编码
            /// </summary>
            public string TLCode  { set { _tlcode= value;} get { return _tlcode ;} }
            /// <summary>
            /// 商店内部编码
            /// </summary>
            public string ShopInnerCode { set { _shopinnercode= value;} get { return _shopinnercode ;} }
            /// <summary>
            /// 商店地址
            /// </summary>
            public string Address { set { _address= value;} get { return _address ;} }
            /// <summary>
            /// 商店级别
            /// </summary>
            public string ShopLev { set { _ShopLev = value; } get { return _ShopLev; } }
            /// <summary>
            /// 销售额
            /// </summary>
            public string SaleVolume { set { _SaleVolume = value; } get { return _SaleVolume; } }
            /// <summary>
            /// 商店面积
            /// </summary>
            public string ShopSquare { set { _ShopSquare = value; } get { return _ShopSquare; } }
            /// <summary>
            /// 甲方企划人
            /// </summary>
            public string PlanMakerName { set { _planmakername= value;} get { return _planmakername ;} }
            /// <summary>
            /// 甲方企划人电话
            /// </summary>
            public string PlanMakerTel { set { _planmakertel= value;} get { return _planmakertel ;} }
            /// <summary>
            /// 甲方营业
            /// </summary>
            public string SalemanName { set { _salemanname= value;} get { return _salemanname  ;} }
            /// <summary>
            /// 甲方营业电话
            /// </summary>
            public string SalemanTel  { set { _salemantel= value;} get { return _salemantel ;} }
            /// <summary>
            /// 代理商（公司）名称
            /// </summary>
            public string AgentClientName { set { _agentclientname= value;} get { return  _agentclientname;} }
            /// <summary>
            /// 代理商（公司）联系人
            /// </summary>
            public string AgentClientLinkman { set {_agentclientlinkman = value;} get { return _agentclientlinkman ;} }
            /// <summary>
            /// 代理商（公司）
            /// </summary>
            public string AgentClientLinkTel { set { _agentclientlinktel= value;} get { return _agentclientlinktel ;} }

            /// <summary>
            /// 各角色工作人员 
            /// </summary>
            public List<OrderWorkTeamModel> WorkTeam { set { _team = value; } get { return _team; } }
            /// <summary>
            /// 订单的文件列表 
            /// </summary>
            public List<OrderFilesModel> FileList { set { _filelist = value; } get { return _filelist; } }
            

        }
    }